//Tue Sep 20 19:22:38 CDT 2011
import java.util.*;
import java.util.regex.*;
import java.text.*;
import java.math.*;
import java.awt.geom.*;

public class HandsShaking
{
	public long cost[];
	
	public long countPerfect(int n)
	{
		cost = new long[n+1];
		for(int i=0; i<=n; i++){
			cost[i] = new Long(-1);
		}
		solve(n);
		return cost[n];
	}

	public void solve(int n){
		if(n==0) cost[n] = 1;
		if(n==2) cost[n] = 1;
		if(cost[n] != -1) return;
		long ret = 0;
		for(int i=1; i<n; i+=2){
			solve(i-1);
			solve(n-i-1);
			ret += cost[i-1] * cost[n-i-1];
		}
		cost[n] = ret;
		return;
	}
	
	
}
//Powered by [KawigiEdit] 2.0!
